package com.nullpointer.xchatfinal.service;

import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;

import com.nullpointer.xchatfinal.utils.DataManager;
import com.nullpointer.xchatfinal.utils.KiraGameLog;

public class ServiceAppBroadcastReceiver extends BroadcastReceiver {

	@Override
	public void onReceive(Context context, Intent intent) {
		KiraGameLog.d("Start xchat service on boot complete");
		DataManager.getInstance(context).setIsAppPause(true);
		context.stopService(new Intent(context, ChatService.class));
		Intent service = new Intent(context, ChatService.class);
		context.startService(service);
	}
}
